From: Brion Vibber Date: Sun, 3 Jul 2005 06:44:53 +0000 (+0000) Subject: * Restore compatibility namespace aliases for French Wikipedia X-Git-Tag: 1.5.0beta2~59 X-Git-Url: http://git.cyclocoop.org/%28%5B%5E/404?a=commitdiff_plain;h=72f46fb64bcbf9db02a6bf4f9eb15231b673a6f0;p=lhc%2Fweb%2Fwiklou.git * Restore compatibility namespace aliases for French Wikipedia reverts change from revision 1.117 --- diff --git a/RELEASE-NOTES b/RELEASE-NOTES index e95385bad1..933b3a02d2 100644 --- a/RELEASE-NOTES +++ b/RELEASE-NOTES @@ -450,6 +450,8 @@ of MediaWiki:Newpagetext) to &action=edit, if page is new. * (bug 2658) Fix signature time, localtime to match timezone offset again * Files from shared repositories (e.g. commons) now display with their image description pages when viewed on local wikis. +* Restore compatibility namespace aliases for French Wikipedia + === Caveats === diff --git a/languages/LanguageFr.php b/languages/LanguageFr.php index d1d1835a86..ec9dbe3182 100644 --- a/languages/LanguageFr.php +++ b/languages/LanguageFr.php @@ -1360,6 +1360,20 @@ class LanguageFr extends LanguageUtf8 { return $wgNamespaceNamesFr; } + + function getNsIndex( $text ) { + global $wgNamespaceNamesFr, $wgSitename; + + foreach ( $wgNamespaceNamesFr as $i => $n ) { + if ( 0 == strcasecmp( $n, $text ) ) { return $i; } + } + if( $wgSitename == "Wikipédia" ) { + if( 0 == strcasecmp( "Wikipedia", $text ) ) return 4; + if( 0 == strcasecmp( "Discussion_Wikipedia", $text ) ) return 5; + } + return false; + } + function getQuickbarSettings() { global $wgQuickbarSettingsFr; return $wgQuickbarSettingsFr;